package com.gyd.marte;

import android.app.Activity;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.ArrayAdapter;
import android.widget.ListView;

public class promocionActivity extends Activity {
	ListView promos;
	String[] datos={"Linux","Window","Mac","Android","otros"};
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_promociones);
        
        promos=(ListView)findViewById(R.id.promo);
        promos.setAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1,datos));
        
        promos.setOnItemClickListener(new OnItemClickListener(){
        	public void onItemClick(AdapterView<?> parent, View view, int position, long id){
        		Log.i("INFOTAG",""+datos[position]);
        	}
        });
        
    }

    
    public void cerrar(View view) {
    	finish();
    }
}
